/* 会员中心共用样式 */

/* 会员中心菜单样式 */
.member-menu {
  display: flex;
  flex-direction: column;
}

.member-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid #f0f0f0;
  transition: all .2s;
}

.member-menu-item:last-child {
  border-bottom: none;
}

.member-menu-item:hover {
  background: var(--primary-weak);
  color: var(--primary);
}

.member-menu-item.active {
  background: var(--primary-weak);
  color: var(--primary);
  font-weight: 600;
}

.member-menu-item i {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

/* 统计卡片样式 */
.member-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: #fafafa;
  border-radius: 10px;
  border: 1px solid #e6eee6;
  transition: all .2s;
  position: relative;
}

.stat-item:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(44, 163, 106, .1);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.stat-content {
  flex: 1;
  min-width: 0;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
}

.stat-label {
  font-size: 13px;
  color: #666;
  margin-top: 4px;
}

.stat-link {
  font-size: 12px;
  color: var(--primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  transition: color .2s;
}

.stat-link:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* 快捷操作样式 */
.member-quick-actions {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #e6eee6;
}

.member-quick-actions h3 {
  margin: 0 0 16px;
  font-size: 16px;
  font-weight: 600;
}

.quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}

.quick-action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px;
  background: #fafafa;
  border: 1px solid #e6eee6;
  border-radius: 10px;
  text-decoration: none;
  color: var(--ink);
  transition: all .2s;
}

.quick-action-item:hover {
  background: var(--primary-weak);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(44, 163, 106, .1);
}

.quick-action-item i {
  font-size: 32px;
  color: var(--primary);
}

.quick-action-item:hover i {
  transform: scale(1.1);
}

.quick-action-item span {
  font-size: 14px;
  font-weight: 500;
}

/* 评论列表样式 */
.comments-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.comment-item {
  padding: 16px;
  background: #fafafa;
  border: 1px solid #e6eee6;
  border-radius: 8px;
}

.comment-content {
  flex: 1;
}

.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.comment-author {
  font-weight: 600;
  color: var(--ink);
  font-size: 14px;
}

.comment-time {
  font-size: 12px;
  color: #999;
}

.comment-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink);
  word-wrap: break-word;
  white-space: pre-wrap;
}

.comment-post-link {
  margin-top: 8px;
  padding: 8px;
  background: #f5f5f5;
  border-radius: 6px;
  font-size: 13px;
  display: flex;
  align-items: center;
}

.comment-post-link a {
  color: var(--primary);
  text-decoration: none;
  margin-left: 6px;
}

.comment-post-link a:hover {
  text-decoration: underline;
}

.comment-status {
  margin-top: 8px;
}

.comment-status-pending {
  padding: 4px 8px;
  background: #fff3cd;
  color: #856404;
  border-radius: 4px;
  font-size: 12px;
}

.comment-status-rejected {
  padding: 4px 8px;
  background: #f8d7da;
  color: #721c24;
  border-radius: 4px;
  font-size: 12px;
}

/* 表单样式 */
.member-form {
  max-width: 600px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--ink);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="date"],
.form-group select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #e6eee6;
  border-radius: 8px;
  font-size: 14px;
  box-sizing: border-box;
  transition: border-color .2s;
}

.form-group input[disabled] {
  background: #f5f5f5;
  color: #999;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px rgba(44, 163, 106, .1);
}

.form-group .form-help {
  font-size: 12px;
  color: #999;
  margin-top: 4px;
}

/* 头像上传 */
.avatar-upload-wrapper {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.avatar-preview-wrapper {
  flex-shrink: 0;
}

.avatar-preview {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #e6eee6;
  background: #f5f5f5;
  transition: all .2s;
}

.avatar-preview:hover {
  opacity: 0.8;
}

.avatar-upload-controls {
  flex: 1;
}

.avatar-file-input {
  display: none;
}

.avatar-upload-btn {
  padding: 8px 16px;
  background: var(--primary-weak);
  color: var(--primary);
  border: 1px solid var(--primary);
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  transition: all .2s;
}

.avatar-upload-btn:hover {
  background: var(--primary) !important;
  color: #fff !important;
}

.avatar-upload-help {
  font-size: 12px;
  color: #999;
  margin-top: 8px;
}

/* 表单操作按钮 */
.form-actions {
  margin-top: 24px;
}

.btn-submit {
  padding: 10px 24px;
  background: var(--primary);
  color: #111;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
}

.btn-submit:hover {
  background: var(--primary-dark) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(44, 163, 106, .3);
}

.btn-submit:disabled {
  background: #ccc !important;
  cursor: not-allowed !important;
  transform: none !important;
}

.btn-cancel {
  padding: 10px 24px;
  margin-left: 12px;
  background: #f5f5f5;
  color: var(--ink);
  border: 1px solid #e6eee6;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  display: inline-block;
  transition: all .2s;
}

.btn-cancel:hover {
  background: #e6eee6;
}

/* 无限滚动加载器 */
.infinite-scroll-loader {
  display: none;
  padding: 20px;
  text-align: center;
  border-top: 1px solid #e6eee6;
  margin-top: 20px;
  animation: fadeIn .3s ease;
}

.infinite-scroll-loader .loading-text {
  color: #999;
}

.infinite-scroll-loader .loading-icon {
  animation: spin 1s linear infinite;
  display: inline-block;
  margin-right: 8px;
}

.infinite-scroll-end {
  padding: 20px;
  text-align: center;
  border-top: 1px solid #e6eee6;
  margin-top: 20px;
  color: #999;
  animation: fadeIn .3s ease;
}

/* 空状态 */
.member-empty-state {
  padding: 40px;
  text-align: center;
  color: #999;
}

.member-empty-state i {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
  opacity: 0.5;
}

/* 动画 */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* 响应式设计 */
@media (max-width: 991.98px) {
  .member-stats {
    grid-template-columns: 1fr;
  }
  
  .quick-actions-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 767.98px) {
  .infinite-scroll-loader {
    padding: 16px;
  }
  
  .infinite-scroll-end {
    padding: 16px;
  }
}

@media (max-width: 575.98px) {
  .stat-item {
    flex-direction: column;
    text-align: center;
  }
  
  .stat-link {
    margin-top: 8px;
  }
  
  .quick-actions-grid {
    grid-template-columns: 1fr;
  }
}

